
package com.jiuqi.ccp.generator.form;

import java.text.ParseException;
import java.text.SimpleDateFormat;

import javax.servlet.http.HttpServletRequest;

import org.apache.struts.action.ActionError;
import org.apache.struts.action.ActionErrors;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionMapping;

/**
 * Form for ccpAclsResmenu.
 *
 * @author <a href="http://boss.bekk.no/boss/middlegen/"/>Middlegen</a>
 *
 * @struts.form name="ccpAclsResmenuForm"
 */
public class CcpAclsResmenuForm extends ActionForm {

   private final static SimpleDateFormat FORMAT = new SimpleDateFormat("dd.MM.yyyy hh:mm:ss");

   private java.lang.String _carGuid = null;
   private java.lang.String _menuTag = null;
   private java.lang.String _menuViewName = null;
   private java.lang.String _menuAdminName = null;
   private java.lang.String _menuDesc = null;
   private java.lang.String _menuUrl = null;
   private java.lang.String _menuParentGuid = null;
   private java.lang.String _menuOrder = null;
   private java.lang.String _menuReserved1 = null;
   private java.lang.String _menuReserved2 = null;
   private java.lang.String _menuReserved3 = null;
   private java.lang.String _menuReserved4 = null;
   private java.lang.String _other1 = null;
   private java.lang.String _other2 = null;
   private java.lang.String _other3 = null;
   private java.lang.String _other4 = null;
   private java.lang.String _other5 = null;

   /**
    * Standard constructor.
    */
   public CcpAclsResmenuForm() {
   }

   /**
    * Returns the carGuid
    *
    * @return the carGuid
    */
   public java.lang.String getCarGuid() {
      return _carGuid;
   }

   /**
    * Sets the carGuid
    *
    * @param carGuid the new carGuid value
    */
   public void setCarGuid(java.lang.String carGuid) {
      _carGuid = carGuid;
   }
   /**
    * Returns the menuTag
    *
    * @return the menuTag
    */
   public java.lang.String getMenuTag() {
      return _menuTag;
   }

   /**
    * Sets the menuTag
    *
    * @param menuTag the new menuTag value
    */
   public void setMenuTag(java.lang.String menuTag) {
      _menuTag = menuTag;
   }
   /**
    * Returns the menuViewName
    *
    * @return the menuViewName
    */
   public java.lang.String getMenuViewName() {
      return _menuViewName;
   }

   /**
    * Sets the menuViewName
    *
    * @param menuViewName the new menuViewName value
    */
   public void setMenuViewName(java.lang.String menuViewName) {
      _menuViewName = menuViewName;
   }
   /**
    * Returns the menuAdminName
    *
    * @return the menuAdminName
    */
   public java.lang.String getMenuAdminName() {
      return _menuAdminName;
   }

   /**
    * Sets the menuAdminName
    *
    * @param menuAdminName the new menuAdminName value
    */
   public void setMenuAdminName(java.lang.String menuAdminName) {
      _menuAdminName = menuAdminName;
   }
   /**
    * Returns the menuDesc
    *
    * @return the menuDesc
    */
   public java.lang.String getMenuDesc() {
      return _menuDesc;
   }

   /**
    * Sets the menuDesc
    *
    * @param menuDesc the new menuDesc value
    */
   public void setMenuDesc(java.lang.String menuDesc) {
      _menuDesc = menuDesc;
   }
   /**
    * Returns the menuUrl
    *
    * @return the menuUrl
    */
   public java.lang.String getMenuUrl() {
      return _menuUrl;
   }

   /**
    * Sets the menuUrl
    *
    * @param menuUrl the new menuUrl value
    */
   public void setMenuUrl(java.lang.String menuUrl) {
      _menuUrl = menuUrl;
   }
   /**
    * Returns the menuParentGuid
    *
    * @return the menuParentGuid
    */
   public java.lang.String getMenuParentGuid() {
      return _menuParentGuid;
   }

   /**
    * Sets the menuParentGuid
    *
    * @param menuParentGuid the new menuParentGuid value
    */
   public void setMenuParentGuid(java.lang.String menuParentGuid) {
      _menuParentGuid = menuParentGuid;
   }
   /**
    * Returns the menuOrder
    *
    * @return the menuOrder
    */
   public java.lang.String getMenuOrder() {
      return _menuOrder;
   }

   /**
    * Sets the menuOrder
    *
    * @param menuOrder the new menuOrder value
    */
   public void setMenuOrder(java.lang.String menuOrder) {
      _menuOrder = menuOrder;
   }
   /**
    * Returns the menuReserved1
    *
    * @return the menuReserved1
    */
   public java.lang.String getMenuReserved1() {
      return _menuReserved1;
   }

   /**
    * Sets the menuReserved1
    *
    * @param menuReserved1 the new menuReserved1 value
    */
   public void setMenuReserved1(java.lang.String menuReserved1) {
      _menuReserved1 = menuReserved1;
   }
   /**
    * Returns the menuReserved2
    *
    * @return the menuReserved2
    */
   public java.lang.String getMenuReserved2() {
      return _menuReserved2;
   }

   /**
    * Sets the menuReserved2
    *
    * @param menuReserved2 the new menuReserved2 value
    */
   public void setMenuReserved2(java.lang.String menuReserved2) {
      _menuReserved2 = menuReserved2;
   }
   /**
    * Returns the menuReserved3
    *
    * @return the menuReserved3
    */
   public java.lang.String getMenuReserved3() {
      return _menuReserved3;
   }

   /**
    * Sets the menuReserved3
    *
    * @param menuReserved3 the new menuReserved3 value
    */
   public void setMenuReserved3(java.lang.String menuReserved3) {
      _menuReserved3 = menuReserved3;
   }
   /**
    * Returns the menuReserved4
    *
    * @return the menuReserved4
    */
   public java.lang.String getMenuReserved4() {
      return _menuReserved4;
   }

   /**
    * Sets the menuReserved4
    *
    * @param menuReserved4 the new menuReserved4 value
    */
   public void setMenuReserved4(java.lang.String menuReserved4) {
      _menuReserved4 = menuReserved4;
   }
   /**
    * Returns the other1
    *
    * @return the other1
    */
   public java.lang.String getOther1() {
      return _other1;
   }

   /**
    * Sets the other1
    *
    * @param other1 the new other1 value
    */
   public void setOther1(java.lang.String other1) {
      _other1 = other1;
   }
   /**
    * Returns the other2
    *
    * @return the other2
    */
   public java.lang.String getOther2() {
      return _other2;
   }

   /**
    * Sets the other2
    *
    * @param other2 the new other2 value
    */
   public void setOther2(java.lang.String other2) {
      _other2 = other2;
   }
   /**
    * Returns the other3
    *
    * @return the other3
    */
   public java.lang.String getOther3() {
      return _other3;
   }

   /**
    * Sets the other3
    *
    * @param other3 the new other3 value
    */
   public void setOther3(java.lang.String other3) {
      _other3 = other3;
   }
   /**
    * Returns the other4
    *
    * @return the other4
    */
   public java.lang.String getOther4() {
      return _other4;
   }

   /**
    * Sets the other4
    *
    * @param other4 the new other4 value
    */
   public void setOther4(java.lang.String other4) {
      _other4 = other4;
   }
   /**
    * Returns the other5
    *
    * @return the other5
    */
   public java.lang.String getOther5() {
      return _other5;
   }

   /**
    * Sets the other5
    *
    * @param other5 the new other5 value
    */
   public void setOther5(java.lang.String other5) {
      _other5 = other5;
   }


   /**
    * Validate the properties that have been set from this HTTP request,
    * and return an <code>ActionErrors</code> object that encapsulates any
    * validation errors that have been found.  If no errors are found, return
    * <code>null</code> or an <code>ActionErrors</code> object with no
    * recorded error messages.
    *
    * @param mapping The mapping used to select this instance
    * @param request The servlet request we are processing
    */
   public ActionErrors validate(ActionMapping mapping, HttpServletRequest request) {
      ActionErrors errors = new ActionErrors();
      // test for nullity
      if(getCarGuid() == null) {
         errors.add("carGuid", new ActionError("error.carGuid.required"));
      }
      // TODO test format/data
      return errors;
   }
}
